/**
 * clients
 *
 * @author xiaomi
 */
'use strict';

const clients = {
    WEB: {
        id: 1,
        name: 'Web',
        alias: 'WEB',
        priority: 1
    },
    IOS: {
        id: 2,
        name: 'iOS',
        alias: 'IOS',
        priority: 1
    },
    ANDROID: {
        id: 4,
        name: 'Android',
        alias: 'ANDROID',
        priority: 1
    }
};

// items
let items = Object.keys(clients)
    .map(k => clients[k])
    .sort((a, b) => b.priority - a.priority);

// export _items
Object.defineProperty(clients, '_items', {
    configurable: true,
    enumerable: false,
    value: items
});

module.exports = clients;
